package com.jabo.douban.demo.presentation.view.activity;

import android.os.Bundle;

import com.jabo.douban.demo.R;
import com.jabo.douban.demo.databinding.ActivityMainBinding;

import androidx.databinding.DataBindingUtil;
import androidx.navigation.NavController;
import androidx.navigation.Navigation;
import androidx.navigation.ui.NavigationUI;

public class MainActivity extends BaseActivity {

    private ActivityMainBinding mMainBinding;
    private NavController mNavController;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        mMainBinding = DataBindingUtil.setContentView(this, R.layout.activity_main);
        mMainBinding.setLifecycleOwner(this);
        mNavController = Navigation.findNavController(this, R.id.fragment);
        mNavController.setGraph(R.navigation.main_navi);
        NavigationUI.setupWithNavController(mMainBinding.bottomNaviView, mNavController);
    }

    @Override
    protected void onResume() {
        super.onResume();
        removeStatusMask();
    }
}
